package com.xj.demo.unknow;

import java.io.File;

public class RenameFile {
    public static void main(String[] args) {
        String filepath = "G:\\donwload\\06-MySQL实战45讲\\03-实践篇 (34讲)";
        File file = new File(filepath);
        File[] files = file.listFiles();
        for (File f : files) {
            String name = f.getName();
            String newName = name.replace("【公益知识库zscc.club】", "").replace("【公益知识库zscc.club】", "");
            f.renameTo(new File(filepath + "\\" + newName));
        }
    }
}
